// 观鸟问题
// 字符串与枚举数据的输入输出

#include <iostream>
using namespace std;

enum BirdType {
    BirdType_robin,
    BirdType_rooster,
    BirdType_canary,
    BirdType_sparrow,
    BirdType_roadrunner,
    BirdType_finch,
    BirdType_eagle,
};

int main() {
    char birds[7][12] = {
        "robin",
        "rooster",
        "canary",
        "sparrow",
        "roadrunner",
        "finch",
        "eagle",
    };

    for (int i = 0; i < 7; i++) {
        cout << (i+1) << " " << birds[i]  << "\n";
    }

    cout << "请输入鸟的种类: ";
    int choice;
    cin >> choice;

    BirdType myBird = (BirdType)(choice-1);
    cout << "你输入的是 " << birds[myBird] << "\n";
}